<?php
$this->layout = '//layouts/column1';

$this->breadcrumbs=array(
	'Manage Members'=>array('Members/admin'),
	$member->first_name." ".$member->last_name=>array('Members/view','id'=>$member->id),
	'Transactions'
);


Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});
$('.search-form form').submit(function(){
	$.fn.yiiGridView.update('transactions-grid', {
		data: $(this).serialize()
	});
	return false;
});
");
?>

<h1>Manage Transactions</h1>

<?php $this->widget('zii.widgets.grid.CGridView', array(
	'id'=>'transactions-grid',
	'enablePagination'=>true,
	'dataProvider'=>$model->search(),
	'columns'=>array(
		array(
			'name'=>'registerredCourse',
			'value'=>'$data->registerredCourse->class_id',
			),
		array(
			'name'=>'member',
			'value'=>'$data->member->first_name . " ". $data->member->last_name',
			),
		'total_amount',
		'discount_value',
		'transaction_note',
		'transaction_type',
		'transaction_date',
		/*
		array(
			'class'=>'CButtonColumn',
		),
		*/
	),
)); ?>
